package com.flying.carclub.http;


import java.util.List;

import okhttp3.Request;
import okhttp3.Response;

/**
 * Created by zuihuibao on 2016/3/29.
 */
public interface IOkHttpApi {
    void executeHttpRequest(ApiHandleParams sender) throws Exception;

    Request buildHttpGetRequest(String url, List<NameValuePair> valuePairs);

    Request buildHttpPostRequest(String url, List<NameValuePair> valuePairs);

    Request buildHttpPostRequest(String url, List<NameValuePair> valuePairs, String cookie);

    Request buildHttpGetRequest(OkRequestParams params);

    Request buildHttpPostRequest(OkRequestParams params);

    Request buildHttpPostStringRequest(OkRequestParams params);

    Request buildHttpPostFileRequest(OkRequestParams params);

    String executeHttpSyncRequest(ApiHandleParams handleParams) throws Exception;

    Response executeHttpSyncRequestReturnResponse(ApiHandleParams handleParams) throws Exception;

//    public Request buildHttpPostMultipart(String url, ArrayList<NameValuePair> valuePairs, ArrayList<ProgressMultipartEntity> filesToUpload);
}
